#include <iostream>
#include <sstream>
#include <stdlib.h>

using namespace std;

int main()
{
    string s1,s2;
    ostringstream oss(ostringstream::out);
    istringstream iss(istringstream::in);
    char c1='+',c2;
    double val,sum=0.0;
    cin>>s2;
    iss.str(s2);
    while (c1!=' '){
        iss>>val>>c2;
        if(c1!=' ') sum=sum+val;
        else if (c1=='-') sum=sum-val;
        c1=c2,c2=' ';
    }
    oss<<sum,s1=oss.str();
    cout<<s1<<endl;

    system("pause");
    return 0;
}